package com.yili.oa.service.impl;

import com.yili.oa.dao.FtGameKindMapper;
import com.yili.oa.models.FtGameKind;
import com.yili.oa.models.FtGameKindExample;
import com.yili.oa.service.FtGameKindService;
import com.yili.oa.utils.annotate.DataBase;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

@Service
@DataBase("lyt_game_db")
@Transactional(value = "transactionManager")
public class FtGameKindServiceImpl implements FtGameKindService {

    @Autowired
    FtGameKindMapper mapper;
    @Override
    public List<FtGameKind> get() {
        FtGameKindExample example = new FtGameKindExample();
        return mapper.selectByExample(example);
    }

    @Override
    public FtGameKind getById(Long id) {
        return mapper.selectByPrimaryKey(id);
    }
}
